package com.teyao.teyao_back.controller;

import com.teyao.teyao_back.entity.ResponseMessage;
import com.teyao.teyao_back.service.VehicleService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.CrossOrigin;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@CrossOrigin
@RequestMapping("/vehicle")
public class VehicleController {
    @Autowired
    private VehicleService vehicleService;

    @GetMapping("/selectAll")
    public ResponseMessage selectAll() {
        return vehicleService.selectAll();
    }

}
